package com.forage.exp.po;

import com.baomidou.mybatisplus.annotation.*;
import com.forage.exp.constant.UserLevelEnum;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author : George
 * @date : 2022-05-3
 *
 * 用户实体
 */
@AllArgsConstructor
@NoArgsConstructor
@Data
@Builder
@TableName("t_user")
public class User {

    /**
     * 用户ID 数据库自增主键
     */
    @TableId(value = "user_id" , type = IdType.AUTO)
    private Integer userId;

    /**
     * 用户账号
     */
    @TableField(value = "user_account")
    private String userAccount;

    /**
     * 用户密码
     */
    @TableField(value = "user_password")
    private String userPassword;

    /**
     * 用户微信唯一ID（备用）
     */
    @TableField(value = "user_wechat")
    private String userWechat;

    /**
     * 用户等级
     */
    @TableField(value = "user_level")
    private UserLevelEnum userLevel;

    /**
     * 用户逻辑删除状态
     */
    @TableLogic
    @TableField(value = "user_deleted", fill = FieldFill.INSERT)
    private Integer deleted;


}
